@use "../global/variables";

.features {
  background-color: variables.$base-white;
}

.features__wrapper {
  margin-bottom: 61px;
  padding-top: 50px;
  text-align: center;
}

.features__head {
  text-transform: uppercase;
  color: variables.$blue-primary;
  font-weight: 700;
  font-size: 12px;
  line-height: 16px;
  margin: 0 0 36px;
}

.features__subtitle {
  font-weight: 700;
  font-size: 24px;
  line-height: 36px;
  margin-bottom: 5px;
}

.features__item {
  position: relative;
  margin-bottom: 33px;
  padding-top: 65px;

  &:last-child {
    margin-bottom: 0;
  }

  &::before {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 52px;
    height: 56px;
    background-repeat: no-repeat;
    content: "";
  }

  &--speed::before {
    background-image: url("../../img/icon-speed.svg");
  }

  &--commfort::before {
    background-image: url("../../img/icon-commfort.svg");
  }

  &--courage::before {
    background-image: url("../../img/icon-courage.svg");
  }

  &--ecology::before {
    background-image: url("../../img/icon-ecology.svg");
  }
}

.features__title {
  color: variables.$base-black;
  font-weight: 700;
  font-size: 18px;
  line-height: 32px;
  display: block;
  margin-bottom: 4px;
}

.features__text {
  margin: 0;
  font-weight: 400;
  font-size: 14px;
  line-height: 20px;
}

@media (min-width: variables.$min-tablet-width) {
  .features {
    padding-bottom: 99px;
  }

  .features__wrapper {
    margin-bottom: 30px;
    padding-top: 60px;
  }

  .features__list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-gap: 50px 10px;
    text-align: left;
  }

  .features__subtitle {
    font-weight: 700;
    font-size: 42px;
    line-height: 64px;
    margin-bottom: 60px;
  }

  .features__head {
    margin-bottom: 4px;
  }

  .features__item {
    margin: 0;
    padding-top: 0;
    padding-left: 82px;

    &::before {
      top: 0;
      left: 10px;
      transform: translateX(0);
    }
  }

  .features__title {
    margin-bottom: 10px;
    font-size: 24px;
    line-height: 36px;
  }

  .features__text {
    font-size: 16px;
    line-height: 24px;
  }
}

@media (min-width: variables.$min-desktop-width) {
  .features {
    padding-bottom: 90px;
  }

  .features__wrapper {
    padding-top: 100px;
  }

  .features__list {
    grid-template-columns: repeat(4, 1fr);
    column-gap: 30px;
  }

  .features__subtitle {
    margin-bottom: 156px;
  }

  .features__item {
    padding-left: 0;
    text-align: center;

    &::before {
      top: -76px;
      left: 50%;
      transform: translateX(-50%);
    }
  }
}
